home *** CD-ROM | disk | FTP | other *** search
/ Crack It! / Crack It!.iso / CONTENT / DISKEDIT / STRINGOF.ASM < prev    next >
Assembly Source File  |  1996-09-09  |  624b  |  30 lines

  1. ;***
  2. ;
  3. ;STRINGOF.ASM - a simple routine to return a string of n instances of
  4. ;               a certain character
  5. ;
  6. ;(C)Copyright Gerard Paul Java 1996
  7. ;
  8. ;***
  9.  
  10. .MODEL TPASCAL
  11.  
  12. .CODE
  13.  
  14.                 PUBLIC  StringOf
  15.  
  16. StringOf        PROC    FAR     CharToRepeat: BYTE,Count: BYTE RETURNS DestString: DWORD
  17.                 LES     DI,DestString
  18.                 MOV     AL,Count
  19.                 STOSB
  20.                 MOV     CL,Count
  21.                 XOR     CH,CH
  22.                 MOV     AL,CharToRepeat
  23.                 REP     STOSB
  24.                 RET
  25. StringOf        ENDP
  26.  
  27.                 END
  28.  
  29.  
  30.